<!DOCTYPE html>
<title>Test that "media" attribute is ignored in "source" element.</title>
<script src="../resources/testharness.js"></script>
<script src="../resources/testharnessreport.js"></script>
<video>
    <source src="content/test.mp4" media="print"></source>
    <source src="content/error.mpeg"></source>
</video>
<script>
async_test(function(t) {
    var video = document.querySelector("video");

    video.onloadstart = t.step_func_done(function() {
        var url = video.currentSrc;
        assert_equals(url.substr(url.lastIndexOf("/media/") + 7), "content/test.mp4");
    });
});
</script>